<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="../js/jquery.js"></script>
</head>
<body>
    <div id="box"></div>
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>

    <script>
        // let oBox = document.getElementById('box');
        // oBox.style.width = '100px';
        // oBox.style.height = '100px';
        // oBox.style.backgroundColor = 'red';

        $('#box').css('width','100px').css('height','100px').css('background','green');
        $('.box').css('width','100px').css('height','100px').css('background','red');
        // 绑定事件

        // $('.box').click(function(){
        //     console.log("hello1");
        // })

        // $('.box').on('click',function(){
        //     console.log("hello2");
        // })

        // $(document).on('click','.box',function(){
        //     console.log("hello3");
        // })
    </script>
</body>
</html>